#include "timercountlauncherwindow.h"
#include "timercountwindow.h"

#include <QVBoxLayout>
#include <QPushButton>

TimerCountLauncherWindow::TimerCountLauncherWindow(QWidget *parent)
    : QWidget(parent)
{
    QVBoxLayout *mainLayout = new QVBoxLayout(this);
    setLayout(mainLayout);

    QPushButton *openBtn = new QPushButton("打开定时器工具", this);
    mainLayout->addWidget(openBtn);

    connect(openBtn, &QPushButton::clicked, this, [] {
        TimerCountWindow *w = new TimerCountWindow;
        w->setAttribute(Qt::WidgetAttribute::WA_DeleteOnClose);
        w->show();
        w->activateWindow();
    });
}

TimerCountLauncherWindow::~TimerCountLauncherWindow()
{
}
